#ifndef _HTTPSERVERRESPONSE_HPP_
#define _HTTPSERVERRESPONSE_HPP_

#include "jhdefs.hpp"
#include "net/HTTPResponse.hpp"
#include <string>
#include <ostream>

NET_NAMESPACE_BEGIN

class CHTTPServerResponse : public CHTTPResponse
{
public:
	CHTTPServerResponse();
	~CHTTPServerResponse();

	virtual void sendContinue() = 0;
	virtual std::ostream& send() = 0;
	virtual void sendFile(const std::string& path, const std::string& mediaType) = 0;
	virtual void sendBuffer(const void* pBuffer, std::size_t length) = 0;
	virtual void redirect(const std::string& uri, HTTPStatus status = HTTP_FOUND) = 0;
	virtual void requireAuthentication(const std::string& realm) = 0;
	virtual bool sent() const = 0;
};

NET_NAMESPACE_END

#endif
